<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>

    <link rel="stylesheet" href="http://cdn.staticfile.org/cesium/1.69.0/Widgets/widgets.css">
    <link rel="stylesheet" href="../css//index.css">
</head>

<body>
    <div class="fun-menu">
        <button onclick="start()">自转</button>
        <button onclick="startByClock()">自转(时钟关联)</button>
        <button onclick="clear1()">清除</button>
    </div>
    <div id=cesiumContainer></div>

    <script src="http://cdn.staticfile.org/cesium/1.69.0/Cesium.js"></script>
    <script src="../libs/cpc/index.js"></script>
    <script>
        const map = new cpc.Map({
            container: "cesiumContainer",
            baseMaps: [
                "http://map.geoq.cn/arcgis/rest/services/ChinaOnlineStreetPurplishBlue/MapServer",
                // {
                //   type: "TDTImageryLayer",
                //   mold: "image",
                //   tk: "7b435c61bff7f77eb49206e10d6397bd",
                // },
            ],
            camera: {
                position: {
                    x: 119.4135823,
                    y: 26.11072,
                    z: 9999999,
                },
                angle: {
                    heading: 0,
                    pitch: -90,
                    roll: 0,
                },
                duration: 3
            },
            viewPort: {
                debugShowFramesPerSecond: true, //帧率是否显示
            },
            cesium: {
                infoBox: false,
                selectionIndicator: false,
                animation: true, //是否创建动画小器件，左下角仪表
                timeline: true, //是否显示时间轴
            },
        });
        function start() {
            map.globalRotate.start();
        }
        function startByClock() {
            map.globalRotate.startByClock();
        }
        function clear1() {
            map.globalRotate.stop();
        }
    </script>
</body>

</html>